package action;

import entity.Todo;
import service.TodoService;

public class DeleteTodoAction {
	private Integer id;
	private String name;
	private String leixing;
	public Integer getId() {
		return id;
	}
	public void setId(Integer id) {
		this.id = id;
	}
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public String getLeixing() {
		return leixing;
	}
	public void setLeixing(String leixing) {
		this.leixing = leixing;
	}
	
	public TodoService getTodoService() {
		return todoService;
	}
	public void setTodoService(TodoService todoService) {
		this.todoService = todoService;
	}

	private TodoService todoService;
	
	public String deleteTodo() throws Exception{
		
		
		todoService.deleteTodoById(id);
		return "selectAllAgain";
	}
}
